home *** CD-ROM | disk | FTP | other *** search
/ PC World 2000 February / PCWorld_2000-02_cd.bin / Software / Vyzkuste / xsetup / _SETUP.2 / Group3 / XQ Logoff Pictures.xpl < prev    next >
Text File  |  1999-10-22  |  2KB  |  81 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 5.0"
  2. "TYPE"="3"
  3. "COUNT"="2"
  4. "UIPATH"="Network\Logoff"
  5. "NAME"="Windows 9x Logoff Pictures"
  6. "VERSION"="1.43"
  7. "LANGUAGE"="VBScript"
  8. "TEXT 1"="Picture 1"
  9. "TEXT 2"="Picture 2"
  10. "DATA 1"="Bitmap picturs (*.BMP)|*.bmp"
  11. "DATA 2"="Bitmap picturs (*.BMP)|*.bmp"
  12. "DESCRIPTION 1"="This plug-in can be used to change the pictures that are displayed when logging off from Windows."
  13. "DESCRIPTION 2"=""Picture 1" is displayed while the computer is shut down (Please wait while...)."
  14. "DESCRIPTION 3"=""Picture 2" is displayed when the computer can be turned off (It's safe now to...)."
  15. "DESCRIPTION 4"="NOTE #1: Both pictures should be 320x400 pixels with 256 colors."
  16. "DESCRIPTION 5"="NOTE #2: Both settings are for Windows 95 or Windows 98."
  17. "AUTHOR"="Xteq Systems"
  18. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  19. "COMMENT 1"="For more information, go to http://www.xteq.com or write to TeXHeX@xteq.com."
  20.  
  21.  
  22. Sub Plugin_Initialize 
  23.  if GetWinVer=1 or GetWinVer=3 then
  24.     'SetUIElement 1,GetWinDir
  25.     'SetUIElement 2,GetWinDir
  26.     SetUIElement 1,"C:\"
  27.     SetUIElement 2,"C:\"
  28.  else  
  29.   Disable
  30.  end if
  31. End Sub
  32.  
  33. Sub Plugin_CheckData(ElementIndex)
  34. End Sub
  35.  
  36. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  37.  s=GetUIElement(1)
  38.  if len(s)>0 then
  39.   Call DoWork("LOGOW.SYS","LOGOW.XSB",s)
  40.   Call Restart
  41.  end if
  42.  
  43.  s=GetUIElement(2)
  44.  if len(s)>0 then
  45.   Call DoWork("LOGOS.SYS","LOGOS.XSB",s)
  46.   Call Restart
  47.  end if
  48.  
  49.  Call MsgInformation("The new logo has been set.")
  50. End Sub
  51.  
  52. Sub Plugin_Terminate 
  53. End Sub
  54.  
  55.  
  56. Sub DoWork(File1,BackupFile,NewFile)
  57.  s1=GetWinDir & File1
  58.  s2=GetWinDir & BackupFile
  59.  s3=NewFile
  60.  
  61.  'if backup exists, delete it
  62.  if FileExists(s2) then
  63.   Call FileSetAttribute(s2,"S-")
  64.   Call FileSetAttribute(s2,"R-")
  65.   Call FileSetAttribute(s2,"H-")
  66.   Call FileDelete(s2)
  67.  end if
  68.  
  69.  'make backup of current file
  70.  if FileExists(s1) then
  71.   Call FileSetAttribute(s2,"S-")
  72.   Call FileSetAttribute(s2,"R-")
  73.   Call FileSetAttribute(s2,"H-")
  74.   Call FileCopy(s1,s2)
  75.   Call FileDelete(s1)
  76.  end if
  77.  
  78.  'now copy new file to old file
  79.  Call FileCopy(s3,s1)
  80. End Sub
  81.